from time import sleep

from singleton import singleton
import modbus_tk.defines as cst
from ModbusManager import ModbusManager
# from gpiozero import Button, LED

@singleton
class Bowl(object):

    # button = Button(2)
    # sig = LED(17)

    def is_ready(self):
        return True
        # return (0 == self.button.value())#传感器是常开还是常闭，这里的值需要做更改

    # 让机械臂搬碗
    def place(self):
        self.sig.blink(on_time=0.1, off_time=0.1, n=1, background=True)


    def do_action(self, params):
        self.place()

    def wait_action(self):
        return True
